package cn.lut;


import cn.lut.domain.SysUser;
import cn.lut.service.UserService;
import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @user:dell
 * @date:2020年10月27 19:28
 */
public class Mytest {
    @Test
    public void  test1(){
      ApplicationContext applicationContext=new ClassPathXmlApplicationContext("applicationContext.xml");
        UserService userService = (UserService) applicationContext.getBean("userService");
        SysUser sysUser=new SysUser();
        sysUser.setAge(15);
        sysUser.setName("路明非");
        userService.addUser(sysUser);

    }

}
